<?php
/**
 * CategoryController
 * 
 * @author
 * @version 
 */
require_once 'Zend/Controller/Action.php';
class News_CategoryController extends Zend_Controller_Action
{
    /**
     * The default action - show the home page
     */
    public function indexAction ()
    {    
        $id = $this->_getParam('cid', 0);
        $catalogModel = new News_Model_Catalog();
        
        $this->view->categories = $catalogModel->getCategoriesByParentId($id);
        
        $this->_helper
            ->viewRenderer
            ->setResponseSegment(
                $this->_getParam('responseSegment')
            );
    }
}

